![]() |
SndControl |
||||
Header: | Sound.h | Carbon status: | Unsupported | |
Obtains information about a sound data type.
OSErr SndControl ( SInt16 id, SndCommand *cmd );
The sound data type you want to get information about. See
A sound command. See the list of sound commands in
A result code.
The SndControl function sends a control command directly to the Sound Manager to get information about a specific data type.
You can call SndControl even if no channel has been created for the type of data you want to get information about. SndControl can be used with the availableCmd or versionCmd sound commands to request information. The requested information is returned in the sound command structure specified by the cmd parameter.
The SndControl function can indicate only whether a particular data format supports some feature (for example, stereo output), not whether the available sound hardware also supports that feature. In general, you should use the Gestalt function to determine whether the sound features you need are available in the current operating environment.
You should not call the SndControl function at interrupt time.
In Sound Manager version 2.0, you can also use the totalLoadCmd and loadCmd commands to get information about the amount of CPU time consumed by sound-related processing. However, these commands are not very accurate and are not supported by version 3.0 and later.
In Sound Manager version 3.0 and later, you virtually never need to call SndControl. The capabilities that SndControl provides are either provided by the Gestalt function or are no longer supported. The SndControl function is documented here for completeness only.
Not supported in Carbon. Not available in Carbon.
This function has been obsolete since Sound Manager 3.0, and is not supported in Carbon. As explained in Inside Macintosh: Sound (page 2-134), Sound Manager 3.0 and the Gestalt Manager include routines that provide this functionality.
© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)